package org.syncsoft.overalt.gui.api;

import javax.swing.JCheckBox;

/**
 * 
 * @author tptfc
 *
 */
@SuppressWarnings("serial")
public class JValuedCheckBox extends JCheckBox {
	private Object value;
	
	public JValuedCheckBox(String name) {
		this(name, true);
	}
	
	public JValuedCheckBox(String name, Object value) {
		super(name);
		setValue(value);
	}

	@SuppressWarnings("unchecked")
	public <T> T getValue() {
		return (T) value;
	}

	private void setValue(Object value) {
		this.value = value;
	}
}
